package com.acme.bankapp.email;

import java.util.LinkedList;

/**
 * Created by Java Student on 11/21/2014.
 */
public class Queue {
    private LinkedList<Email> emailList = new LinkedList<>();

    public void add(Email email){
        emailList.add(email);
    }

    public Email getEmail(){
        return emailList.remove();
    }

    public boolean isEmpty(){
        return  emailList.isEmpty();
    }

    @Override
    public String toString() {
        return emailList.toString();
    }
}
